//
//  WBComposeTypeButton.swift
//  GitWeibo
//
//  Created by 胡金东 on 2017/6/15.
//  Copyright © 2017年 胡金东. All rights reserved.
//

import UIKit

class WBComposeTypeButton: UIControl {

    /// - 发布弹出框图片
    @IBOutlet var composeImage: UIImageView!
    /// - 发布弹出宽标题
    @IBOutlet var composeTitle: UILabel!
    
    class func compostTypeButton(imageName:String,title:String) -> WBComposeTypeButton {
        let nib = UINib(nibName: "WBComposeTypeButton", bundle: nil)
        let composeBtn = nib.instantiate(withOwner: nil, options: nil)[0] as! WBComposeTypeButton
        
        composeBtn.composeImage.image = UIImage(named: imageName)
        composeBtn.composeTitle.text = title
        
       return composeBtn
    }
    
   }
